﻿using BusinessObjects.BusinessRules;

namespace BusinessObjects.BussinessVoucher
{
    /// <summary>
    /// FixedAssetArmortizationDetail
    /// </summary>
    public class FixedAssetArmortizationDetail : BusinessObject
    {
        /// <summary>
        /// Initializes a new instance of the <see cref="FixedAssetArmortizationDetail"/> class.
        /// </summary>
        public FixedAssetArmortizationDetail()
        {
            AddRule(new ValidateRequired("RefId"));
            AddRule(new ValidateRequired("FixedAssetId"));
            AddRule(new ValidateRequired("AccountNumber"));
            AddRule(new ValidateRequired("CorrespondingAccountNumber"));
        }

        /// <summary>
        /// Initializes a new instance of the <see cref="FixedAssetArmortizationDetail"/> class.
        /// </summary>
        /// <param name="refDetailId">The reference detail identifier.</param>
        /// <param name="refId">The reference identifier.</param>
        /// <param name="fixedAssetId">The fixed asset identifier.</param>
        /// <param name="accountNumber">The account number.</param>
        /// <param name="correspondingAccountNumber">The corresponding account number.</param>
        /// <param name="description">The description.</param>
        /// <param name="quantity">The quantity.</param>
        /// <param name="amount"> </param>
        /// <param name="voucherTypeId">The voucher type identifier.</param>
        /// <param name="departmentId">The department identifier.</param>
        /// <param name="projectId">The project identifier.</param>
        /// <param name="uintId"> </param>
        public FixedAssetArmortizationDetail(long refDetailId, long refId, int fixedAssetId, string accountNumber, string correspondingAccountNumber, string description,
            int quantity, decimal amount, long voucherTypeId,  long departmentId, long projectId)
            : this()
        {
            RefDetailId = refDetailId;
            RefId = refId;
            FixedAssetId = fixedAssetId;
            AccountNumber = accountNumber;
            CorrespondingAccountNumber = correspondingAccountNumber;
            Quantity = quantity;
            Amount = amount;
            VoucherTypeId = voucherTypeId;
            Description = description;
            DepartmentId = departmentId;
            ProjectId = projectId;
        }

        /// <summary>
        /// Gets or sets the reference detail identifier.
        /// </summary>
        /// <value>
        /// The reference detail identifier.
        /// </value>
        public long RefDetailId { get; set; }

        /// <summary>
        /// Gets or sets the reference identifier.
        /// </summary>
        /// <value>
        /// The reference identifier.
        /// </value>
        public long RefId { get; set; }

        /// <summary>
        /// Gets or sets the fixed asset identifier.
        /// </summary>
        /// <value>
        /// The fixed asset identifier.
        /// </value>
        public long FixedAssetId { get; set; }

        /// <summary>
        /// Gets or sets the account number.
        /// </summary>
        /// <value>
        /// The account number.
        /// </value>
        public string AccountNumber { get; set; }

        /// <summary>
        /// Gets or sets the corresponding account number.
        /// </summary>
        /// <value>
        /// The corresponding account number.
        /// </value>
        public string CorrespondingAccountNumber { get; set; }

        /// <summary>
        /// Gets or sets the description.
        /// </summary>
        /// <value>
        /// The description.
        /// </value>
        public string Description { get; set; }

        /// <summary>
        /// Gets or sets the quantity.
        /// </summary>
        /// <value>
        /// The quantity.
        /// </value>
        public int Quantity { get; set; }

        /// <summary>
        /// Gets or sets the amount oc.
        /// </summary>
        /// <value>
        /// The amount oc.
        /// </value>
        public decimal Amount { get; set; }

        /// <summary>
        /// Gets or sets the voucher type identifier.
        /// </summary>
        /// <value>
        /// The voucher type identifier.
        /// </value>
        public long VoucherTypeId { get; set; }

        /// <summary>
        /// Gets or sets the department identifier.
        /// </summary>
        /// <value>
        /// The department identifier.
        /// </value>
        public long DepartmentId { get; set; }

        /// <summary>
        /// Gets or sets the project identifier.
        /// </summary>
        /// <value>
        /// The project identifier.
        /// </value>
        public long ProjectId { get; set; }
    }
}
